package com.example.mansystem.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.mansystem.entity.UserDO;
import com.example.mansystem.vo.UserVO;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface UserMapper extends BaseMapper<UserDO> {

    int selectCountByUsername(String username);

    boolean updateUser(@Param("id") Integer id,
                       @Param("name") String name,
                       @Param("roleid") Integer roleid,
                       @Param("sex") String sex,
                       @Param("username") String username,
                       @Param("departmentId") String departmentId);

    List<UserDO> getAllUser();
}
